//
//  TableFiveViewController.m
//  Advertisement
//
//  Created by mac on 16/4/5.
//  Copyright © 2016年 Appcoda. All rights reserved.
//

#import "TableFiveViewController.h"

@interface TableFiveViewController ()

@end

@implementation TableFiveViewController
-(void)viewWillAppear:(BOOL)animated
{
    UIWebView * webview = [[UIWebView alloc]initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height)];
    NSURL * url = [NSURL URLWithString:self.string];
    NSURLRequest *request = [NSURLRequest requestWithURL:url];
    [webview loadRequest:request];
    webview.scalesPageToFit = YES;
    [self.view addSubview:webview];
    
    
//    UIWebView * webview = [[UIWebView alloc]initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height)];
////    _userdefaults1 = [NSUserDefaults standardUserDefaults];
////    
////    NSString *idString =[NSString stringWithFormat:@"%@", [_userdefaults1 valueForKey:@"row1"]];
////    int count = [idString intValue];
////    NSLog(@"1111111111111--%d",count);
//    NSString * string = nil;
//    if (self.myIndex ==1) {
//        string = @"http://www.baidu.com";
//    }else if (self.myIndex==2){
//        string = @"http://47.88.76.185/sx/html/DMOS.html" ;
//    }else if (self.myIndex==3){
//        string =@"http://47.88.76.185/sx/html/DRAMS.html" ;
//    }else if (self.myIndex==4){
//        string = @"http://47.88.76.185/sx/html/MEMS.html";
//    }else if (self.myIndex==5){
//        string = @"http://47.88.76.185/sx/html2/FEP.html";
//    }else if (self.myIndex==6){
//        string = @"http://47.88.76.185/sx/html2/IC 应用.html";
//    }else if (self.myIndex==7){
//        string = @"http://47.88.76.185/sx/html2/IC封装.html";
//    }else if (self.myIndex==8){
//        string = @"http://47.88.76.185/sx/html2/IC 设计.html";
//    }else if (self.myIndex==9){
//        string = @"http://47.88.76.185/sx/html2/LOGIC.html";
//    }else if (self.myIndex==10){
//        string = @"http://47.88.76.185/sx/html2/MEOMORY.html";
//    }else if (self.myIndex==11){
//        string = @"http://47.88.76.185/sx/html2/电子元器件.html";//http://47.88.76.185/sx/html2/电子元器件.html
//    }else{
//        string = @"http://47.88.76.185/sx/html2/硅晶片.html";//http://47.88.76.185/sx/html2/硅晶片.html
//    }
//    NSLog(@"22222222-%@",string);
//    NSURL * url = [NSURL URLWithString:string];
//    NSURLRequest *request = [NSURLRequest requestWithURL:url];
//    [webview loadRequest:request];
//    webview.scalesPageToFit = YES;
//    [self.view addSubview:webview];
}

- (void)viewDidLoad {
    [super viewDidLoad];
   self.title = @"详情页面";
    
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
